-- CALC_DEVICE_MATERIAL_BAG_BONUS

-- 计算天空改造材料包奖励
-- @param user     玩家对象
return function(user)
    -- 随机飞艇材料：1阶×10、2阶×5、3阶×3、4阶×2
    local ret  = {};
    local rand1 = RandomFactoryM.myRandom(ME.user) % 4;
    local rand2 = RandomFactoryM.myRandom(ME.user) % 4;
    local rand3 = RandomFactoryM.myRandom(ME.user) % 4;
    local rand4 = RandomFactoryM.myRandom(ME.user) % 4;

    local material = { 10400, 10401, 10402, 10403, };
    table.insert(ret, {1, material[rand1 + 1], 10});

    material = { 10404, 10405, 10406, 10407, };
    table.insert(ret, {1, material[rand2 + 1], 5});

    material = { 10408, 10409, 10410, 10411, };
    table.insert(ret, {1, material[rand3 + 1], 3});

    material = { 10412, 10413, 10414, 10415, };
    table.insert(ret, {1, material[rand4 + 1], 2});

    return ret;
end
